<template>
    <div>
        <h2>
           子组件--childtwo
        </h2>
        <button @click="changeParent">去修改父组件</button>
        <div>
            <input type="text" @input="changeparentworld">
        </div>
        <button @click="changeshow">反向props修改父组件</button>
    </div>
</template>
<script>
export default {
    name:'childtwo',
    props: {
        changeshow:Function
    },
    methods: {
        changeParent(){
            this.$parent.count +=0.1
        },
        changeparentworld(e){
            this.$emit('changeparentworld', e.target.value)
        }
    }
}
</script>